window.vm = {}
require(['vue', 'cube', 'fastclick', 'common', 'toast', require.toUrl('./root.js')], function (Vue, Cube, FastClick, app, toast) {
  Cube.install(Vue)
  Vue.use(toast)
  FastClick.attach(document.body)
  // app.openFrame()
  vm = new Vue({
    el: '#app',
    data: {

    },
    mounted () {
      // this.$toast()
    },
    methods: {
      showToast () {
        this.$toast()
      },
      test () {
        alert('ok')
      }
    }
  })

  //   window.apiready = function () {
  //     alert(api.winHeight)
  //   }
  console.log(app)
  setTimeout(function () {
    app.apiready(function () {
    //   alert(api.winHeight)
    })
  }, 0)
  app.fixStatusBar('.app-nav-bar')
})
